package com.zrrd.learn.chapter08面向对象.pattern.proxy;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * ProxyImage
 *
 * @author wrn
 * @version 1.0
 * @date 2023/8/4 10:44
 */
@Data
@AllArgsConstructor
public class ProxyImage implements Image {

    private Reallmage reallmage;
    private String fileName;

    public ProxyImage() {

    }

    public ProxyImage(Reallmage reallmage) {
        this.reallmage = reallmage;
    }

    @Override
    public void display() {

        reallmage.display();

        System.out.println(this.getFileName() + "我帮你修图后显示的照片");
    }
}
